//
//  HCDiscoverViewController.swift
//  Hweibome
//
//  Created by 何川 on 15/12/6.
//  Copyright © 2015年 hechuan. All rights reserved.
//

import UIKit

class HCDiscoverViewController: HCVisitorTableViewController {

    override func viewDidLoad() {
        super.viewDidLoad()
        
        if !userLogin {
            visitorView?.setVisitorInfo("visitordiscover_image_message", message: "登录后，最新、最热微博尽在掌握，不再会与实事潮流擦肩而过")
            return
        }

         setupUI()
        
    }

    func setupUI(){
        let searchView = HCDiscoverSearchView.searchView()
        searchView.frame = CGRect(x: 0, y: 0, width: UIScreen.mainScreen().bounds.width, height: 35)
        
        navigationItem.titleView = searchView
       
        //tabBarItem.badgeValue = "badgeValue"
        
//        for tabBarChild in self.tabBarController!.tabBar.subviews{
//            if tabBarChild.isKindOfClass(NSClassFromString("UITabBarButton")!){
//                // 继续往下找
//                for tabBarButtonChild in tabBarChild.subviews {
//                    if tabBarButtonChild.isKindOfClass(NSClassFromString("_UIBadgeView")!) {
//                        for badgeViewChild in tabBarButtonChild.subviews {
//                            if badgeViewChild.isKindOfClass(NSClassFromString("_UIBadgeBackground")!) {
//                                printLog("终于等于你,还好没放弃")
//                            }
//                        }
//                    }
//                }
//            }
//    }
//    
    }

}
